import textComp from './textComp'

let obj = {
  textComp
}

//info.type:就是组件的名称
let getComponent = (info,attr,data) => {
  let component = obj[info.type](attr,data)
  component.info = info 
  return component
}
export default getComponent